package com.feri.openapi.controller;

import com.feri.openapi.dto.SmsDto;
import com.feri.openapi.service.SmsService;
import com.feri.openapi.vo.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class SmsController {

    @Autowired
    private SmsService smsService;

    //发送
@PostMapping("provider/sms/sendSms.do")
public R sendSms(@RequestBody SmsDto dto){
    return smsService.sendMsg(dto);
}
    //校验
    @PostMapping("provider/sms/checkcode.do")
    public R checkCode(@RequestBody SmsDto dto){
        return smsService.sendMsg(dto);
    }
}
